<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" isELIgnored ="false"%>
<%@ taglib uri="/struts-tags" prefix="s"%>
<%
	String path = request.getContextPath();
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
	<head>
		<title>北京市电子行政监察平台-会议置办</title>
				<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
		<link href="<%=path%>/css/base.css" rel="stylesheet" type="text/css" />
		<link href="<%=path%>/css/frame.css" rel="stylesheet" type="text/css" />
		<link href="<%=path%>/css/style.css" rel="stylesheet" type="text/css" />
		<link href="<%=path%>/css/jquery.treeview.css" rel="stylesheet" type="text/css" />
		<link href="<%=path%>/css/jQueryTree-1.2.1.css" rel="stylesheet" type="text/css" />
		<%@ include file="../../conference_getOnlineInfoFromSession.jsp"%>
		<script type="text/javascript">
			var path = "<%=path%>";
		</script>
		<script type="text/javascript" src="<%=path%>/javascript/core/jquery-1.4.3.pack.js"></script>
		<script type="text/javascript" src="<%=path%>/javascript/core/jquery-jtemplates.pack.js"></script>
		<script type="text/javascript" src="<%=path%>/javascript/core/jquery.form.js"></script>
		<script type="text/javascript" src="<%=path%>/javascript/core/jquery.metadata.js"></script>
		<script type="text/javascript" src="<%=path%>/javascript/core/jquery.validate.fixed.pack.js"></script>
		<!-- 联系人 -->
		<script type="text/javascript" src="<%=path%>/javascript/core/jquery.treeview.pack.js"></script>
		<script type="text/javascript" src="<%=path%>/javascript/system/oacore.js"></script>
		<script type="text/javascript" src="<%=path%>/javascript/system/jQueryTree-1.2.1.min.js"></script>
		<script type="text/javascript" src="<%=path%>/javascript/system/AccountBook2.js"></script>

		<script type="text/javascript" src="<%=path%>/javascript/system/util.js"></script>
		<!-- end  -->
		<!-- 时间选择器 -->
		<script language="javascript" type="text/javascript" src="<%=path%>/javascript/My97DatePicker/WdatePicker.js"></script>
		<!-- end -->
		<script type="text/javascript" src="<%=path%>/javascript/system/init.js"></script>
		<!-- 在线文档 -->
		<script type="text/javascript" src="<%=path%>/javascript/webOffice/commons.js"></script>
		<script type="text/javascript">
		var accountBookJsonStr = "<%=((String)request.getAttribute("userInfoString"))%>";
			$(function () {

					//初始化联系人
					new AccountBook({
						input: $(".use-account-book"),
						mode: "single",
						defaultValue: [],
						data: $.parseJSON(accountBookJsonStr),
						pretreatment: function (data) {
							data.content = data.userName;
							delete data.userName;
							data.id = data.userInfoId;
							delete data.userInfoId;
							return data;
						}
					});
				
					//初始化去向选择器
					var selector = $("input.nextstep-option").bind("click", function () {
							var $this = $(this);
							if($this.hasClass("nextstep-option-sendback"))
							{
								$("tr.nextstep-continue").hide();
								$("tr.nextstep-sendback").show();
								$("#accountBook").val("");
								$("#accountBook").addClass("ignore");
							}
							else if($this.hasClass("nextstep-option-continue"))
							{
								$("tr.nextstep-sendback").hide();
								$("tr.nextstep-continue").show();
								$("#accountBook").removeClass("ignore");
							}
							else if($this.hasClass("nextstep-option-sure"))
							{
								$("tr.nextstep-sendback").hide();
								$("tr.nextstep-continue").hide();
								$("#accountBook").val("");
								$("#accountBook").addClass("ignore");
							}
						});
					//触发选择
					selector.filter(":checked").trigger("click");
				});
		</script>
		<style type="text/css">
			div {
				position: static;
			}
		</style>
	</head>
	<body onunload="UnLoad();">
		<div id="mainPage" class="surround-layout">
		<jsp:include page="/jsp/frame/top.jsp" flush="true"></jsp:include>
			<div class="middle">
				<s:if test="fromFlag=='task'">
					<jsp:include page="../../../frame/middle_left.jsp" flush="true">
						<jsp:param value="1001-1034" name="view"/>
					</jsp:include>
				</s:if>
				<s:else>
					<jsp:include page="../../../frame/middle_left.jsp" flush="true">
						<jsp:param value="1018-1034" name="view"/>
					</jsp:include>
				</s:else>
				<!-- 右侧输出内容 -->
				<div class="right">
					<div class="right-all-content">
						<div>
							<div class="content-line-wrap">
								<div class="content-line-left content-line">
									<h1 class="content-title">
										<span>
											<a href="<%=path %>/web/toUserAccountListAction.action">会议置办</a>
										</span>
										<span>
											&gt;&gt;
										</span>
										<span>
											<a href="<%=path %>/web/toCreatePageAction.action">处理</a>
										</span>
									</h1>
								</div>
							</div>
							<div class="inner-dialog">
								<h1 class="inner-dialog-title">
									会议方案审批
								</h1>
								<div class="inner-dialog-content">
									<form method="post" name="webform" id="creatorForm" class="normal-form use-def-validate" onsubmit="SaveDocument();" action="<%=path%>/web/schemeApprovalSubmitAction.action">
										<input type="hidden"   name="onlinePath" id="path"/>
									    <input type="hidden"   name="onlineVersion" id="documentVersion"/>
									    <input type="hidden" name="fromFlag" value="fromFlag">
									    <input type="hidden" name="jobId" value="${jobId }"></input>
									    
										<h1 class="inner-form-title">会议任务信息</h1>
										<table class="data-view-table tiny-form-table view-mode" cellspacing="0">
											<tbody>
												<tr class="odd">
													<td class="dvt-filed">
														会议任务名称:
													</td>
													<td colspan="3" class="dvt-value">
														${missionDTO.missionName }
													</td>
												</tr>
												<tr class="even">
													<td class="dvt-filed">
														任务编号:
													</td>
													<td class="dvt-value">
														${missionDTO.missionCode }
													</td>
													<td class="dvt-filed">
														创建人:
													</td>
													<td class="dvt-value">
														${missionDTO.creatorDTO.userName }
													</td>
												</tr>
												<tr class="odd">
													<td class="dvt-filed">
														来源:
													</td>
													<td class="dvt-value">
														${missionDTO.importanceDTO.value }
													</td>
													<td class="dvt-filed">
														任务计划结束日期:
													</td>
													<td class="dvt-value">
													<s:date name="missionDTO.scheduleEndDate" format="yyyy-MM-dd"/>
													</td>
												</tr>
												<tr class="even">
													<td class="dvt-filed">
														任务描述:
													</td>
													<td class="dvt-value" colspan="3">
														${missionDTO.description }&nbsp;
													</td>
												</tr>
											</tbody>
										</table>
										<h1 class="inner-form-title">审批方案</h1>
										<div style="height: 540px;">
											<script src="<%=path%>/javascript/webOffice/iWebOffice2009.js"></script>
										</div>
										
										<table class="data-view-table tiny-form-table" cellspacing="0">
											<tbody>
												<tr class="odd">
													<td class="dvt-filed">
														<span class="important-field-star">*</span>
														审批意见:
													</td>
													<td class="dvt-value">
														<textarea class="shadow tft-textarea {required: true, dataName: true, maxlength: 32, messages: {required: '审批意见项为必填', maxlength: '审批意见项的长度不能超过32个字符', dataName: '审批意见的格式须为中英文、数字及下划线'}}" name="schemeJobData.opinion"></textarea>
													</td>
												</tr>
												<tr class="even">
													<td class="dvt-filed">
														<span class="important-field-star">*</span>
														下一步去向:
													</td>
													<td class="dvt-value">
														<label class="tft-radiolabel odd">
															<input type="radio" name="next" value="SUBMIT_NEXT_APPROVAL" class="nextstep-option nextstep-option-continue" checked="checked"/> 继续审批（交给下一位领导审批）
														</label>
														<label class="tft-radiolabel even">
															<input type="radio" name="next" value="SENDBACK" class="nextstep-option nextstep-option-sendback"/> 转回承办人（转回承办人对文档做进一步完善）
														</label>
														<label class="tft-radiolabel odd">
															<input type="radio" name="next" value="AGREE_FINALIZE" class="nextstep-option nextstep-option-sure"/> 批准定稿（文档符合要求，同意承办人定稿）
														</label>
													</td>
												</tr>
												<tr class="odd nextstep-continue" style="display: none;">
													<td class="dvt-filed">
														<span class="important-field-star">*</span>
														下一批示人:
													</td>
													<td class="dvt-value">
														<input type="text" class="shadow tft-textinput use-account-book {required: true, messages: {required: '下一批示人项为必选'}}" id="accountBook" name="schemeJobData.nextApproval.UserInfoId"/>
													</td>
												</tr>
												<tr class="odd nextstep-sendback" style="display: none;">
													<td class="dvt-filed">
														<span class="important-field-star">*</span>
														承办人:
													</td>
													<td class="dvt-value">
														<input type="text" value="${missionDTO.creatorDTO.userName }" class="shadow tft-textinput" readonly="readonly" id="undertaker"/>
														<input type="hidden" value="${missionDTO.creatorDTO.userInfoId }" name="undertakerId"></input>
													</td>
												</tr>
											</tbody>
										</table>
										<table>
											<tr>
												<td>
													<input type="submit" value="确定" class="special originate"></input>
												</td>
											</tr>
										</table>
									</form>
								</div>
							</div>
						</div>
					</div>
				</div>
				<!--  -->
			</div>
		</div>
	</body>
</html>